From de822639a208f5e815ca07a110ad5e89b38e8ffa Mon Sep 17 00:00:00 2001 From: Keir Fraser Date: Sat, 22 May 2010 06:36:41 +0100 Subject: [PATCH] iommu: Gracefully fail to initialise iommu on generic x86 platforms. Signed-off-by: Keir Fraser --- xen/include/asm-x86/hvm/iommu.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/xen/include/asm-x86/hvm/iommu.h b/xen/include/asm-x86/hvm/iommu.h index 13b4c56eb5..d488edff4d 100644 --- a/xen/include/asm-x86/hvm/iommu.h +++ b/xen/include/asm-x86/hvm/iommu.h @@ -1,6 +1,8 @@ #ifndef __ASM_X86_HVM_IOMMU_H__ #define __ASM_X86_HVM_IOMMU_H__ +#include + struct iommu_ops; extern const struct iommu_ops intel_iommu_ops; extern const struct iommu_ops amd_iommu_ops; @@ -31,7 +33,7 @@ static inline int iommu_hardware_setup(void) case X86_VENDOR_AMD: return amd_iov_detect(); default: - BUG(); + return -ENODEV; } return 0; -- 2.30.2